<template>
  <mumu-get-qrcode @success='qrcodeSucess' :definition="true"  @error="qrcodeError"></mumu-get-qrcode>
</template>

<script>
	import mumuGetQrcode from '@/uni_modules/mumu-getQrcode/components/mumu-getQrcode/mumu-getQrcode.vue'
export default {
	components: {
		mumuGetQrcode
	},
  data() {
    return {
    };
  },
  methods: {
   qrcodeSucess(data) {
		uni.$emit("sendewmcode",data)
		uni.navigateBack(1)
   },
   qrcodeError(err) {
   	console.log(err)
   	uni.showModal({
   		title: '攝像頭授權失敗',
   		content: '攝像頭授權失敗，請检测当前瀏覽器是否有攝像頭權限。',
   		success: () => {
   			uni.navigateBack({})
   		}
   	})
   },
  },
};
</script>

<style></style>
